package ws

import "gitee.com/gao-deguang/easy-chat/pkg/constant"

type (
	Msg struct {
		MsgId          string `mapstructure:"msgId"`
		constant.Mtype `mapstructure:"mType"`
		Content        string `mapstructure:"content"`
	}

	Chat struct {
		ConversationId    string `mapstructure:"conversationId"`
		constant.ChatType `mapstructure:"chatType"`
		SendId            string `mapstructure:"sendId"`
		RecvId            string `mapstructure:"recvId"`
		Msg               `mapstructure:"msg"`
		SendTime          int64 `mapstructure:"sendTime"`
	}

	Push struct {
		ConversationId    string `mapstructure:"conversationId"`
		constant.ChatType `mapstructure:"chatType"`
		SendId            string            `mapstructure:"sendId"`
		RecvServerAddr    string            `mapstructure:"RecvServerAddr"`
		RecvId            string            `mapstructure:"recvId"`
		RecvIds           []string          `mapstructure:"recvIds"`
		SendTime          int64             `mapstructure:"sendTime"`
		ReadRecords       map[string]string `mapstructure:"readRecords"`
		constant.Mtype    `mapstructure:"mType"`
		MsgId             string               `mapstructure:"msgId"`
		ContentType       constant.ContentType `mapstructure:"contentType"`
		Content           string               `mapstructure:"content"`
	}

	MarkRead struct {
		constant.ChatType `mapstructure:"chatType"`
		RecvId            string   `mapstructure:"recvId"`
		ConversationId    string   `mapstructure:"conversationId"`
		MsgIds            []string `mapstructure:"msgIds"`
	}
)
